Skip to content

feat(providers): add OrcaRouter as a named provider - #376

Open
putraperdana1207-pixel wants to merge 1 commit into
EverMind-AI:mainfrom
putraperdana1207-pixel:feat/add_orcarouter_provider
Open

feat(providers): add OrcaRouter as a named provider#376
putraperdana1207-pixel wants to merge 1 commit into
EverMind-AI:mainfrom
putraperdana1207-pixel:feat/add_orcarouter_provider

Conversation

@putraperdana1207-pixel

Copy link
Copy Markdown

Summary

This adds OrcaRouter as a first-class provider in Raven's registry, mirroring how OpenRouter is wired in. OrcaRouter is an OpenAI-compatible AI gateway built for both models and agents. Like OpenRouter, it exposes a provider/model namespace across many models -- but it also combines adaptive routing, automatic failover, zero-markup inference, observability, guardrails, and agent-tool governance behind the same endpoint. Adding orcarouter as a named provider means Raven's users can use that stack directly, without treating OrcaRouter as an anonymous custom base URL.

LiteLLM carries no orcarouter route, so the gateway is reached through the OpenAI driver while keeping the full model namespace on the wire (openai/<namespace>/<model>). A bare router name such as orcarouter/auto keeps its orcarouter/ prefix so the upstream recognises it.

It also runs gateway-level, zero-trust security for AI agents on the same endpoint -- screening every prompt/response and governing every tool call on a default-deny basis, with no application code changes.

Changes:

  • raven/providers/registry.py: add the orcarouter ProviderSpec (key-prefix detection sk-orca-, default api base https://api.orcarouter.ai/v1, via_driver="openai") and a via_driver_preserves_namespace gateway flag.
  • raven/providers/wire.py: build the wire form for a namespace-preserving gateway (swap only the gateway's own prefix for the driver's; keep orcarouter/auto prefixed).
  • raven/config/schema.py: declare the orcarouter provider section.
  • raven/providers/common_models.py / raven/cli/onboard_commands.py / README: surface OrcaRouter in the curated model shortlist, the onboarding picker, and the provider catalog.
  • Tests: wire-form conversion cases, gateway detection by key/base, LiteLLM resolution through the OpenAI driver, and the regenerated wire-model baseline.

Verification (local, Python 3.12):

  • uv run --frozen pytest -q -> 7126 passed (two unrelated pre-existing environment-dependent failures on main: test_everos_server real-ps detection and a TERM-sensitive rich render assertion).
  • uv run ruff check + uv run ruff format --check on the changed files -> clean.
  • Live against https://api.orcarouter.ai/v1 through Raven's LiteLLMProvider wire path: orcarouter/auto, orcarouter/openai/gpt-5.5, and orcarouter/anthropic/claude-haiku-4.5 each returned 200.

Type

  • Feature
  • Fix
  • Docs
  • CI / tooling
  • Refactor
  • Other

Verification

  • Relevant tests pass locally
  • Relevant lint / type checks pass locally
  • User-facing docs or screenshots are updated when needed

Risk

  • Security impact considered
  • Backward compatibility considered
  • Rollback path is clear for risky changes

Backward compatible: the change only adds a provider; existing gateway behavior (OpenRouter, AiHubMix) is covered by the same wire-model tests and unchanged.

Related Issues

N/A

I'm an engineer on the OrcaRouter team.

Discord: discord.gg/YEubt8enRA - X: https://x.com/OrcaRouter

Add OrcaRouter, an OpenAI-compatible AI gateway, as a first-class
provider alongside OpenRouter. LiteLLM carries no "orcarouter" route,
so the gateway is reached through the OpenAI driver with the full model
namespace kept on the wire ("openai/<namespace>/<model>"); a bare
router name such as "orcarouter/auto" keeps its prefix so the upstream
recognises it.

- registry: add orcarouter ProviderSpec (sk-orca- key detection, default
  api base https://api.orcarouter.ai/v1, via_driver=openai)
- wire: support a gateway whose upstream keeps the full model namespace
- config: declare the orcarouter section in the provider schema
- onboarding / model picker / README: surface OrcaRouter in the catalog
- tests: wire-form conversion, gateway detection, LiteLLM resolution,
  and the regenerated wire-model baseline

Co-authored-by: Claude (deepseek-v4-flash-0731) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant